Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(iota-core): handle cost overflowing in shared object congestion tracker #4739

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

semenov-vladyslav
Copy link
Contributor

Description of change

Correctly handle tx cost arithmetic overflows in shared object congestion tracker. Upper bound max_accumulated_txn_cost_per_object_in_commit is allowed to be u64::MAX.

Links to any relevant issues

Fixes #4177.

Type of change

Choose a type of change, and delete any options that are not relevant.

  • Bug fix (a non-breaking change which fixes an issue)

How the change has been tested

Added unit test to cover edge cases.

Change checklist

Tick the boxes that are relevant to your changes, and delete any items that are not.

  • I have followed the contribution guidelines for this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that new and existing unit tests pass locally with my changes

@semenov-vladyslav semenov-vladyslav requested review from a team as code owners January 9, 2025 18:55
@iota-ci iota-ci added core-protocol node Issues related to the Core Node team labels Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core-protocol node Issues related to the Core Node team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use saturating_add in shared_object_congestion_tracker.rs
2 participants